package com.troubadorian.feeds;



import com.troubadorian.feeds.R;

import android.app.Activity;
import android.app.AlertDialog;
import android.app.ProgressDialog;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.content.IntentFilter;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager.NameNotFoundException;
import android.os.AsyncTask;
import android.os.Bundle;
import android.preference.PreferenceManager;
import android.provider.Settings.Secure;
import android.util.Log;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ProgressBar;
import android.widget.TextView;
import android.widget.Toast;


public class SplashScreenActivity extends Activity 
{

	private TextView buttonLogin;

	private TextView buttonBack;
	
	private TextView buttonSignal;
	

	private static final String TAG = "LoginScreenActivity";


	@Override
	public void onCreate(Bundle savedInstanceState)
	{
		super.onCreate(savedInstanceState);


		this.setContentView(R.layout.activity_splash);

		buttonLogin = (TextView) this.findViewById(R.id.buttonLogin);

		buttonBack = (TextView) this.findViewById(R.id.buttonBack);
		
		buttonSignal = (TextView) this.findViewById(R.id.buttonSignal);

		PackageInfo pinfo = null;
		try
		{
			pinfo = getPackageManager().getPackageInfo(getPackageName(), 0);
		} catch (NameNotFoundException e)
		{
			// TODO Auto-generated catch block
			e.printStackTrace();
		} finally
		{
			String displayString = "Version : " + pinfo.versionName + "b"
					+ pinfo.versionCode;

		}


		buttonLogin.setOnClickListener(new View.OnClickListener()
		{

			@Override
			public void onClick(View v)
			{
				Intent intent = new Intent(SplashScreenActivity.this, MainActivity.class);
				startActivity(intent);
			}

		});
		
		buttonBack.setOnClickListener(new View.OnClickListener()
		{
			
			@Override
			public void onClick(View v)
			{
				Intent intent = new Intent(SplashScreenActivity.this, MainActivity.class);
				startActivity(intent);				
			}
		});
		
		buttonSignal.setOnClickListener(new View.OnClickListener()
		{
			
			@Override
			public void onClick(View v)
			{
				Intent intent = new Intent(SplashScreenActivity.this, ScrollableTabsActivity.class);
				startActivity(intent);
				
			}
		});

	}

}
